﻿using System;
using System.Collections.Generic;
using System.Collections;
using System.Text;
using Castle.ActiveRecord;
using NHibernate.Expression;
using Castle.ActiveRecord.Framework.Config;
using RmitTimeSheet.Domain;
using Castle.ActiveRecord.Framework;

namespace RmitTimeSheet.Manager
{
    public class FunctionForDatabase
    {
        public static void ConnectDatabse()
        {
            try
            {
                IConfigurationSource source = ActiveRecordSectionHandler.Instance;
                ActiveRecordStarter.Initialize(source, typeof(TimeSheet));
            }
            catch (Exception ex)
            {
                //_logger.Error("Error when Init ", ex);
                throw ex;
            }
        }


    }
}
